package com.pxst.annotations.validated;

import javax.validation.Constraint;
import javax.validation.Payload;
import java.lang.annotation.*;

/**
 * @author rj
 * @create 2023-09-25-16:50
 */
@Documented
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.METHOD, ElementType.FIELD, ElementType.ANNOTATION_TYPE, ElementType.CONSTRUCTOR, ElementType.PARAMETER, ElementType.TYPE_USE})
@Constraint(validatedBy = {DecimalValidated.class})
public @interface DecimalValidator {

    String message() default "起始金额不能大于结束金额";

    Class<?>[] groups() default {}; // 分组校验

    Class<? extends Payload>[] payload() default { };
}
